<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateAkbusTaskSalaryElectricRankTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('akbus_task_salary_electric_rank', function (Blueprint $table) {
            $table->bigIncrements('id');
            $table->integer('line')->nullable()->comment('线路');
            $table->string('license_plate_num')->nullable()->comment('车牌号');
            $table->date('date')->nullable()->comment('日期');
            $table->tinyInteger('total_grade')->nullable()->comment('得分');
            $table->tinyInteger('ranking')->nullable()->comment('排名');
            $table->string('reward_punish_text')->nullable()->comment('奖励/惩罚');
            $table->decimal('should_reward_punish',10,2)->nullable()->comment('应奖励/惩罚');
            $table->decimal('real_reward_punish',10,2)->nullable()->comment('实际奖励/惩罚');
            $table->string('driver')->nullable()->comment('司机');
            $table->decimal('work_day',10,2)->nullable()->comment('出勤天数');
            $table->decimal('day_money',10,2)->nullable()->comment('元/天');
            $table->decimal('reward_punish_money',10,2)->nullable()->comment('奖惩金额');
            $table->text('remark')->nullable()->comment('备注');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('akbus_task_salary_electric_rank');
    }
}
